﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using BioModel;

namespace BioWCF
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the interface name "IService1" in both code and config file together.
    [ServiceContract]
    public interface IRemoteBookingSystem
    {
        #region Film
        [OperationContract]
        string GetFilm(string titel, int aar);
        [OperationContract]
        void NyFilm(string titel, string instruktoer, string beskrivelse, string genre, string laengde, bool aktiv, string billede, bool er3D, double billetPris, List<string> kunstner);
        [OperationContract]
        List<Film> AlleFilm();
        [OperationContract]
        List<Film> AlleAktiveFilm(bool status);
        [OperationContract]
        Film GetEnFilm(int filmID);
        [OperationContract]
        Film GetEnFilmFraTitel(string titel);
        #endregion

        #region Kunde
        [OperationContract]
        void InsertKunde(int telefonNr, string navn, string email, string password);
        [OperationContract]
        void EditKunde(int telefonNr, string navn, string email);
        [OperationContract]
        List<Kunde> AlleKunder();
        [OperationContract]
        Kunde GetEnKunde(int tlf);
        #endregion

        #region Salg
        [OperationContract]
        void NySalg(DateTime datoOprettet, int antalBilletter, string salgsType, double totalPris, int forestilling, int kundeTlf, List<Saede> s);
        [OperationContract]
        Salg GetEnSalg(int salgId);
        [OperationContract]
        List<Salg> GetAlleSalg(int telefonNr);
        [OperationContract]
        void EditSalg(int telefonNr, string salgsType);
        #endregion

        #region Sal
        [OperationContract]
        int InsertSal(int antalPladser, bool er3D);

        [OperationContract]
        void EditSal(int salNr, bool er3D);

        [OperationContract]
        List<Sal> AlleSal();

        [OperationContract]
        List<Sal> Alle3DSal(bool status);

        [OperationContract]
        Sal GetEnSal(int salNr);

        [OperationContract]
        void SletEnSal(int salId);
        #endregion

        #region Forestilling
        [OperationContract]
        int InsertForestilling(DateTime fremvisningsDato, string start, string slut, int film, int sal);
        [OperationContract]
        void EditForestilling(int forestillingId, DateTime fremvisningsDato, string start, string slut, int film, int sal);
        [OperationContract]
        List<Forestilling> AlleForestillinger();
        [OperationContract]
        Forestilling GetEnForestilling(int forestillingId);
        [OperationContract]
        Forestilling GetEnForestillingAfDatoOgTid(DateTime dato, string tid);
        [OperationContract]
        Forestilling GetForestillingsIdFraFrilmIdDatoOgTid(int filmId, DateTime dato, string tid);
        [OperationContract]
        List<Forestilling> GetForestillingerFraFilmId(int filmId);
        [OperationContract]
        List<Forestilling> GetForestillingerFraDato(DateTime dato);
        [OperationContract]
        List<Forestilling> GetForestillingerFraDatoOgFilmId(DateTime dato, int filmId);
        [OperationContract]
        List<Forestilling> GetForestillingerFraDatoFilmIdOgTid(DateTime dato, int filmId, string tid);
        [OperationContract]
        Forestilling GetForestillingId(int filmId, DateTime forestillingsDato, string startTid, int salId);
        #endregion

        #region Sæde
        [OperationContract]
        int GetMaxSal(string kolonneNavn, int sal);

        [OperationContract]
        void InsertSaede(int saedeNr, int raekkeNr, int forestillingsId);

        [OperationContract]
        void EditSaede(int saedeId, string saedeStatus);

        [OperationContract]
        List<Saede> AlleSaeder();

        [OperationContract]
        List<Saede> AlleSaederFraForestilling(int forestillingsId);

        [OperationContract]
        Saede GetEnSaede(int saedeId);

        [OperationContract]
        void SletEnSaede(int salId);
        #endregion

        #region Betaling
        [OperationContract]
        int InsertBetaling(DateTime betalingsDato, bool betalingsStatus);
        [OperationContract]
        void EditBetaling(int betalingsId, DateTime betalingsDato, bool betalingsStatus);
        [OperationContract]
        List<Betaling> AlleBetalinger();
        [OperationContract]
        Betaling GetEnBetaling(int betalingsId);
        #endregion

    }
}
